.TH "fwList" 3 "13 Oct 2009" "Version 2" "zebulon" \" -*- nroff -*-
.ad l
.nh
.SH NAME
fwList \- 
.PP
Provide simple list managment.  

.SH SYNOPSIS
.br
.PP
.PP
\fC#include <fwList.h>\fP
.SS "Public Member Functions"

.in +1c
.ti -1c
.RI "\fBfwList\fP ()"
.br
.RI "\fIBasic constructor, initialization, Create an empty list. \fP"
.ti -1c
.RI "\fBfwList\fP (\fBfwList\fP &l)"
.br
.RI "\fICopy constructor. \fP"
.ti -1c
.RI "virtual \fB~fwList\fP ()"
.br
.RI "\fI\fBfwList\fP destructor \fP"
.ti -1c
.RI "void \fBnext\fP (void)"
.br
.RI "\fIposition the current element on the next one \fP"
.ti -1c
.RI "void \fBprevious\fP (void)"
.br
.RI "\fIposition the current element on the previous one \fP"
.ti -1c
.RI "void \fBfront\fP (void)"
.br
.RI "\fIPosition the current element on the first element of the list. \fP"
.ti -1c
.RI "void \fBend\fP (void)"
.br
.RI "\fIPosition the current element on the last element of the list. \fP"
.ti -1c
.RI "bool \fBoutside\fP (void) const "
.br
.RI "\fITest if the current element is outside the list (on the virtual element). \fP"
.ti -1c
.RI "bool \fBempty\fP (void) const "
.br
.RI "\fITest if the list is empty. \fP"
.ti -1c
.RI "type & \fBvalue\fP (void)"
.br
.RI "\fIreturn the value of the current element \fP"
.ti -1c
.RI "const type & \fBvalue\fP (void) const "
.br
.RI "\fIreturn the value of the current element using a const ref. \fP"
.ti -1c
.RI "void \fBsuppress\fP (void)"
.br
.RI "\fIsuppress the current element \fP"
.ti -1c
.RI "void \fBkill\fP ()"
.br
.RI "\fIDestroy the list. \fP"
.ti -1c
.RI "void \fBdisplay\fP ()"
.br
.RI "\fIPrint (std::cout) all the element of the list. \fP"
.ti -1c
.RI "void \fBprint\fP ()"
.br
.ti -1c
.RI "void \fBaddRight\fP (const type &el)"
.br
.RI "\fIadd a new element in the list, at the right of the current one \fP"
.ti -1c
.RI "void \fBaddLeft\fP (const type &el)"
.br
.RI "\fIadd a new element in the list, at the left of the current one \fP"
.ti -1c
.RI "void \fBmodify\fP (const type &el)"
.br
.RI "\fIModify the value of the current element. \fP"
.ti -1c
.RI "void \fBaddRight\fP (type &el)"
.br
.RI "\fIadd a new element in the list, at the right of the current one \fP"
.ti -1c
.RI "void \fBaddLeft\fP (type &el)"
.br
.RI "\fIadd a new element in the list, at the left of the current one \fP"
.ti -1c
.RI "int \fBnbElement\fP (void)"
.br
.RI "\fIreturn the number of element in the list \fP"
.ti -1c
.RI "int \fBnbElements\fP (void)"
.br
.RI "\fIreturn the number of element in the list \fP"
.ti -1c
.RI "void \fBoperator=\fP (\fBfwList\fP< type > &l)"
.br
.RI "\fICopy constructor. \fP"
.ti -1c
.RI "void \fBoperator+=\fP (\fBfwList\fP< type > &l)"
.br
.RI "\fIAppend two lists. \fP"
.ti -1c
.RI "void \fBoperator+=\fP (const type &l)"
.br
.RI "\fIAppend an element to a list. \fP"
.ti -1c
.RI "bool \fBnextOutside\fP (void) const "
.br
.RI "\fITest if the next element is outside the list (ie if the current element is the last one). \fP"
.ti -1c
.RI "bool \fBpreviousOutside\fP (void) const "
.br
.RI "\fITest if the previous element is outside the list (ie if the current element is the firts one). \fP"
.ti -1c
.RI "type & \fBpreviousValue\fP (void)"
.br
.RI "\fIreturn the value of the previous element \fP"
.ti -1c
.RI "type & \fBnextValue\fP (void)"
.br
.RI "\fIreturn the value of the next element \fP"
.ti -1c
.RI "type & \fBfirstValue\fP (void)"
.br
.RI "\fIreturn the first element of the list \fP"
.ti -1c
.RI "type & \fBlastValue\fP (void)"
.br
.RI "\fIreturn the last element of the list \fP"
.ti -1c
.RI "\fBfwList\fP (\fBfwList\fP &l)"
.br
.ti -1c
.RI "void \fBnext\fP (void)"
.br
.ti -1c
.RI "void \fBprevious\fP (void)"
.br
.ti -1c
.RI "void \fBfront\fP (void)"
.br
.ti -1c
.RI "void \fBend\fP (void)"
.br
.ti -1c
.RI "bool \fBoutside\fP (void) const "
.br
.ti -1c
.RI "bool \fBempty\fP (void) const "
.br
.ti -1c
.RI "type & \fBvalue\fP (void)"
.br
.ti -1c
.RI "const type & \fBvalue\fP (void) const "
.br
.ti -1c
.RI "void \fBsuppress\fP (void)"
.br
.ti -1c
.RI "void \fBkill\fP ()"
.br
.ti -1c
.RI "void \fBdisplay\fP ()"
.br
.ti -1c
.RI "void \fBprint\fP ()"
.br
.ti -1c
.RI "void \fBaddRight\fP (const type &el)"
.br
.ti -1c
.RI "void \fBaddLeft\fP (const type &el)"
.br
.ti -1c
.RI "void \fBmodify\fP (const type &el)"
.br
.ti -1c
.RI "void \fBaddRight\fP (type &el)"
.br
.ti -1c
.RI "void \fBaddLeft\fP (type &el)"
.br
.ti -1c
.RI "int \fBnbElement\fP (void)"
.br
.ti -1c
.RI "int \fBnbElements\fP (void)"
.br
.ti -1c
.RI "void \fBoperator=\fP (\fBfwList\fP< type > &l)"
.br
.ti -1c
.RI "void \fBoperator+=\fP (\fBfwList\fP< type > &l)"
.br
.ti -1c
.RI "void \fBoperator+=\fP (const type &l)"
.br
.ti -1c
.RI "bool \fBnextOutside\fP (void) const "
.br
.ti -1c
.RI "bool \fBpreviousOutside\fP (void) const "
.br
.ti -1c
.RI "type & \fBpreviousValue\fP (void)"
.br
.ti -1c
.RI "type & \fBnextValue\fP (void)"
.br
.ti -1c
.RI "type & \fBfirstValue\fP (void)"
.br
.ti -1c
.RI "type & \fBlastValue\fP (void)"
.br
.in -1c
.SS "Public Attributes"

.in +1c
.ti -1c
.RI "int \fBnb\fP"
.br
.ti -1c
.RI "\fBfwListElement\fP< type > * \fBfirst\fP"
.br
.RI "\fIthe first virtual item in the list \fP"
.ti -1c
.RI "\fBfwListElement\fP< type > * \fBlast\fP"
.br
.RI "\fIthe last virtualitem in the list \fP"
.ti -1c
.RI "\fBfwListElement\fP< type > * \fBcur\fP"
.br
.RI "\fIthe current item in the list \fP"
.in -1c
.SH "Detailed Description"
.PP 

.SS "template<class type> class fwList< type >"
Provide simple list managment. 

\fBAuthor:\fP
.RS 4
Eric Marchand (Eric.Marchand@irisa.fr) Irisa / Inria Rennes
.RE
.PP
.PP
.nf

  Data structure:
    each object fwListElement contains its own value and
    two pointers to the next element of the list and to the previous one

    A list is mainly a pointer to three of these elements
      - one (cur) points the current element
      - one (first) points to a virtual element located at the
        beginning of the list
      - one (last) points  to a virtual element located at the
        end of the list

      first, last and cur are used internally and are not to be considered
      by "basic" user.

  Notation:
    In this documentation we note such a list as
          [*, a, b, c, *]
           f     ^     l
    where
     - the * are the two virtual elements (first (f) and last (l))
     - the ^ denotes the position of the current element

  .fi
.PP
 
.SH "Constructor & Destructor Documentation"
.PP 
.SS "template<class type > \fBfwList\fP< type >::\fBfwList\fP ()\fC [inline]\fP"
.PP
Basic constructor, initialization, Create an empty list. .PP
.nf

  init() --> [*, *]
  .fi
.PP
 
.PP
\fBSee also:\fP
.RS 4
init() 
.RE
.PP

.SS "template<class type > \fBfwList\fP< type >::\fBfwList\fP (\fBfwList\fP< type > & l)\fC [inline]\fP"
.PP
Copy constructor. \fBRemarks:\fP
.RS 4
Cannot define this function as usual, ie, : \fCtemplate<class type> fwList<type>::fwList(const fwList<type>& l)\fP since the list is indeed modified (not the element but the position of the current element.
.RE
.PP
\fBSee also:\fP
.RS 4
\fBoperator=(fwList<type>& l)\fP 
.RE
.PP

.SS "template<class type > \fBfwList\fP< type >::~\fBfwList\fP ()\fC [inline, virtual]\fP"
.PP
\fBfwList\fP destructor \fBSee also:\fP
.RS 4
\fBkill()\fP 
.RE
.PP

.SH "Member Function Documentation"
.PP 
.SS "template<class type > void \fBfwList\fP< type >::addLeft (type & v)\fC [inline]\fP"
.PP
add a new element in the list, at the left of the current one \fBWarning:\fP
.RS 4
the new element becomes the current one
.RE
.PP
.PP
.nf

  [*, a, b, c, *]  --> addLeft(i) -->   [*, a, i, b, c, *]
         ^                                     ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::addLeft (const type & v)\fC [inline]\fP"
.PP
add a new element in the list, at the left of the current one \fBWarning:\fP
.RS 4
the new element becomes the current one
.RE
.PP
.PP
.nf

  [*, a, b, c, *]  --> addLeft(i) -->   [*, a, i, b, c, *]
         ^                                     ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::addRight (type & v)\fC [inline]\fP"
.PP
add a new element in the list, at the right of the current one \fBWarning:\fP
.RS 4
the new element becomes the current one
.RE
.PP
.PP
.nf

  [*, a, b, c, *]  --> addRight(i) -->   [*, a, b, i, c, *]
         ^                                         ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::addRight (const type & v)\fC [inline]\fP"
.PP
add a new element in the list, at the right of the current one \fBWarning:\fP
.RS 4
the new element becomes the current one
.RE
.PP
.PP
.nf

  [*, a, b, c, *]  --> addRight(i) -->   [*, a, b, i, c, *]
         ^                                         ^
  .fi
.PP
 
.SS "template<class type > bool \fBfwList\fP< type >::empty (void) const\fC [inline]\fP"
.PP
Test if the list is empty. .PP
.nf

  [*, a, b, c, d, *]  --> empty return false
  [*, *]              --> empty return true
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::end (void)\fC [inline]\fP"
.PP
Position the current element on the last element of the list. .PP
.nf

  [*, a, b, c, d, *]  --> end() --> [*, a, b, c, d, *]
         ^                                         ^
  .fi
.PP
 
.SS "template<class type > type & \fBfwList\fP< type >::firstValue (void)\fC [inline]\fP"
.PP
return the first element of the list .PP
.nf

   [*, a, b, c, d, *]  --> firstValue() return a
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::front (void)\fC [inline]\fP"
.PP
Position the current element on the first element of the list. .PP
.nf

  [*, a, b, c, d, *]  --> front() --> [*, a, b, c, d, *]
         ^                                ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::kill ()\fC [inline]\fP"
.PP
Destroy the list. .PP
.nf

  [*, a, b, c, *]  --> kill -->   [*, *]
         ^                            ^
  .fi
.PP
 
.SS "template<class type > type & \fBfwList\fP< type >::lastValue (void)\fC [inline]\fP"
.PP
return the last element of the list .PP
.nf

   [*, a, b, c, d, *]  --> lastValue() return d
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::modify (const type & v)\fC [inline]\fP"
.PP
Modify the value of the current element. .PP
.nf

  [*, a, b, c, *]  --> modify(i) -->   [*, a, i, c, *]
         ^                                    ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::next (void)\fC [inline]\fP"
.PP
position the current element on the next one .PP
.nf

  [*, a, b, c, d, *] --> next() -->   [*, a, b, c, d, *]
         ^                                      ^
  .fi
.PP
 
.SS "template<class type > bool \fBfwList\fP< type >::nextOutside (void) const\fC [inline]\fP"
.PP
Test if the next element is outside the list (ie if the current element is the last one). .PP
.nf

  [*, a, b, c, d, *]  --> nextOutside return true
               ^
  .fi
.PP
 
.SS "template<class type > type & \fBfwList\fP< type >::nextValue (void)\fC [inline]\fP"
.PP
return the value of the next element .PP
.nf

  [*, a, b, c, d, *]  --> nextValue() return c
         ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::operator+= (const type & l)\fC [inline]\fP"
.PP
Append an element to a list. .PP
.nf

  [*, a, b, *] += c --> [*, a, b, c, *]
                                  ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::operator+= (\fBfwList\fP< type > & l)\fC [inline]\fP"
.PP
Append two lists. .PP
.nf

  [*, a, b, *] += [*, c, d, *] --> [*, a, b, c, d, *]
                                                ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::operator= (\fBfwList\fP< type > & l)\fC [inline]\fP"
.PP
Copy constructor. \fBRemarks:\fP
.RS 4
Cannot define this function as usual, ie, : \fCtemplate<class type> fwList<type>::fwList(const fwList<type>& l)\fP since the list is indeed modified (not the element but the position of the current element. 
.RE
.PP

.SS "template<class type > bool \fBfwList\fP< type >::outside (void) const\fC [inline]\fP"
.PP
Test if the current element is outside the list (on the virtual element). .PP
.nf

  [*, a, b, c, d, *]  --> outside return false
         ^
  [*, a, b, c, d, *]  --> outside return true
   ^      or      ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::previous (void)\fC [inline]\fP"
.PP
position the current element on the previous one .PP
.nf

  [*, a, b, c, d, *] --> previous() -->   [*, a, b, c, d, *]
         ^                                ^
  .fi
.PP
 
.SS "template<class type > bool \fBfwList\fP< type >::previousOutside (void) const\fC [inline]\fP"
.PP
Test if the previous element is outside the list (ie if the current element is the firts one). .PP
.nf

  [*, a, b, c, d, *]  --> nextOutside return true
      ^
  .fi
.PP
 
.SS "template<class type > type & \fBfwList\fP< type >::previousValue (void)\fC [inline]\fP"
.PP
return the value of the previous element .PP
.nf

  [*, a, b, c, *]  --> previousValue() return a
         ^
  .fi
.PP
 
.SS "template<class type > void \fBfwList\fP< type >::suppress (void)\fC [inline]\fP"
.PP
suppress the current element \fBWarning:\fP
.RS 4
new current element is on the next one
.RE
.PP
.PP
.nf

  [*, a, b, c, d, *] --> suppress -->  [*, a, c, d, *]
         ^                                    ^
  .fi
.PP
 
.SS "template<class type > const type & \fBfwList\fP< type >::value (void) const\fC [inline]\fP"
.PP
return the value of the current element using a const ref. .PP
.nf

  [*, a, b, c, *]  --> value() return b
         ^
  .fi
.PP
 
.SS "template<class type > type & \fBfwList\fP< type >::value (void)\fC [inline]\fP"
.PP
return the value of the current element .PP
.nf

  [*, a, b, c, *]  --> value() return b
         ^
  .fi
.PP
 
.SH "Member Data Documentation"
.PP 
.SS "template<class type> \fBfwListElement\fP< type > * \fBfwList\fP< type >::\fBcur\fP"
.PP
the current item in the list .PP
.nf

          [*, a, b, c, *]
                 ^
    .fi
.PP
 
.SS "template<class type> \fBfwListElement\fP< type > * \fBfwList\fP< type >::\fBfirst\fP"
.PP
the first virtual item in the list .PP
.nf

          [*, a, b, c, *]
           f
    .fi
.PP
 
.SS "template<class type> \fBfwListElement\fP< type > * \fBfwList\fP< type >::\fBlast\fP"
.PP
the last virtualitem in the list .PP
.nf

          [*, a, b, c, *]
                       l
    .fi
.PP
 

.SH "Author"
.PP 
Generated automatically by Doxygen for zebulon from the source code.
